package com.pine.common.database.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 基础实体
 *
 * @author pine manage
 * @since 2024-11-05
 */
@Data
public class BaseEntity<ID> {

    @Schema(description = "主键")
    @TableId(value = "id", type = IdType.AUTO)
    private ID id;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @Schema(description = "逻辑删除(0-未删除 1-已删除)")
    private Integer deleted;
}
